package na.learn.java.corepatterns.pooling;

import java.sql.CallableStatement;
import java.sql.DatabaseMetaData;
import java.sql.PreparedStatement;
import java.sql.SQLException;
import java.sql.SQLWarning;
import java.sql.Savepoint;
import java.sql.Statement;
import java.util.Map;

public class Connection implements java.sql.Connection {

	private java.sql.Connection conn;

	public Connection() {
		super();
	}

	public Statement createStatement() throws SQLException {
		return conn.createStatement();
	}

	public PreparedStatement prepareStatement(String arg0) throws SQLException {
		return conn.prepareStatement(arg0);
	}

	public CallableStatement prepareCall(String arg0) throws SQLException {
		return conn.prepareCall(arg0);
	}

	public String nativeSQL(String arg0) throws SQLException {
		return conn.nativeSQL(arg0);
	}

	public void setAutoCommit(boolean arg0) throws SQLException {
		conn.setAutoCommit(arg0);

	}

	public boolean getAutoCommit() throws SQLException {
		// TODO Auto-generated method stub
		return conn.getAutoCommit();
	}

	public void commit() throws SQLException {
		conn.commit();

	}

	public void rollback() throws SQLException {
		conn.rollback();

	}

	public void close() throws SQLException {
		conn.close();

	}

	public boolean isClosed() throws SQLException {

		return conn.isClosed();
	}

	public DatabaseMetaData getMetaData() throws SQLException {
		return conn.getMetaData();
	}

	public void setReadOnly(boolean arg0) throws SQLException {
		conn.setReadOnly(arg0);

	}

	public boolean isReadOnly() throws SQLException {
		return conn.isReadOnly();
	}

	public void setCatalog(String arg0) throws SQLException {
		conn.setCatalog(arg0);

	}

	public String getCatalog() throws SQLException {
		return conn.getCatalog();
	}

	public void setTransactionIsolation(int arg0) throws SQLException {
		conn.setTransactionIsolation(arg0);

	}

	public int getTransactionIsolation() throws SQLException {
		return conn.getTransactionIsolation();
	}

	public SQLWarning getWarnings() throws SQLException {
		return conn.getWarnings();
	}

	public void clearWarnings() throws SQLException {
		// TODO Auto-generated method stub

	}

	public Statement createStatement(int arg0, int arg1) throws SQLException {

		return conn.createStatement(arg0, arg1);
	}

	public PreparedStatement prepareStatement(String arg0, int arg1, int arg2)
			throws SQLException {
		return conn.prepareStatement(arg0, arg1, arg2);
	}

	public CallableStatement prepareCall(String arg0, int arg1, int arg2)
			throws SQLException {

		return conn.prepareCall(arg0, arg1, arg2);
	}

	public Map<String, Class<?>> getTypeMap() throws SQLException {
		return conn.getTypeMap();
	}

	public void setTypeMap(Map<String, Class<?>> arg0) throws SQLException {
		conn.setTypeMap(arg0);

	}

	public void setHoldability(int arg0) throws SQLException {
		conn.setHoldability(arg0);

	}

	public int getHoldability() throws SQLException {

		return conn.getHoldability();
	}

	public Savepoint setSavepoint() throws SQLException {
		return conn.setSavepoint();
	}

	public Savepoint setSavepoint(String arg0) throws SQLException {
		return conn.setSavepoint(arg0);
	}

	public void rollback(Savepoint arg0) throws SQLException {
		conn.rollback();

	}

	public void releaseSavepoint(Savepoint arg0) throws SQLException {
		// TODO Auto-generated method stub

	}

	public Statement createStatement(int arg0, int arg1, int arg2)
			throws SQLException {

		return conn.createStatement(arg0, arg1, arg2);
	}

	public PreparedStatement prepareStatement(String arg0, int arg1, int arg2,
			int arg3) throws SQLException {
		// TODO Auto-generated method stub
		return null;
	}

	public CallableStatement prepareCall(String arg0, int arg1, int arg2,
			int arg3) throws SQLException {

		return conn.prepareCall(arg0, arg1, arg2, arg3);
	}

	public PreparedStatement prepareStatement(String arg0, int arg1)
			throws SQLException {

		return conn.prepareStatement(arg0, arg1);
	}

	public PreparedStatement prepareStatement(String arg0, int[] arg1)
			throws SQLException {

		return conn.prepareStatement(arg0, arg1);
	}

	public PreparedStatement prepareStatement(String arg0, String[] arg1)
			throws SQLException {

		return conn.prepareStatement(arg0, arg1);
	}

}
